package sword_offers

type Node struct {
	Val    int
	Next   *Node
	Random *Node
}

type N struct {
	Val     int
	NextVal *int
	Random  *int
}

func copyRandomNode(n *Node) *Node {
	s := make([]N, 0)
	for n.Next != nil {
		s = append(s, N{
			Val:     n.Val,
			NextVal: &n.Next.Val,
			Random:  &n.Random.Val,
		})
	}
}
